<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.5"/>
<title>QCNSim: QcnSim/EventChainElement.cpp Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">QCNSim
   </div>
   <div id="projectbrief">Simulator for Quake-Catcher Network</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.5 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>File&#160;Members</span></a></li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Macros</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_d21be12960473ba5c51e5f9beea3525e.html">QcnSim</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">EventChainElement.cpp</div>  </div>
</div><!--header-->
<div class="contents">
<a href="_event_chain_element_8cpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;</div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="_event_chain_element_8h.html">EventChainElement.h</a>&quot;</span></div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;</div>
<div class="line"><a name="l00040"></a><span class="lineno"><a class="line" href="class_event_chain_element.html#a5ea840974f6ff43044e2ae6323b8241c">   40</a></span>&#160;<a class="code" href="class_event_chain_element.html#a5ea840974f6ff43044e2ae6323b8241c">EventChainElement::EventChainElement</a>(<span class="keywordtype">double</span> eventTime, <span class="keyword">const</span> <a class="code" href="class_event.html">Event</a> &amp;event): eventTime(eventTime), event(event) {</div>
<div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;}</div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;</div>
<div class="line"><a name="l00053"></a><span class="lineno"><a class="line" href="_event_chain_element_8cpp.html#add80734c355c74ce27444a2f7d24aa59">   53</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="_event_chain_element_8cpp.html#add80734c355c74ce27444a2f7d24aa59">operator&lt;</a>(<span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;left, <span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;right)  {</div>
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;    <span class="keywordflow">return</span> left.<a class="code" href="class_event_chain_element.html#ae3d6217ce76ebe8603b89383ed63e7c6">eventTime</a> &lt; right.<a class="code" href="class_event_chain_element.html#ae3d6217ce76ebe8603b89383ed63e7c6">eventTime</a>;</div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;    <span class="comment">// For priority_queue container, this should actually be true if left.eventTime &gt;= right.eventTime.</span></div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;    <span class="comment">// But then the operator &lt; breaks if a real &lt; comparison is wanted.</span></div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;}</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;</div>
<div class="line"><a name="l00069"></a><span class="lineno"><a class="line" href="_event_chain_element_8cpp.html#acabbca299f7a82dfe7a696f41f812f20">   69</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="_event_chain_element_8cpp.html#acabbca299f7a82dfe7a696f41f812f20">operator&gt;</a>(<span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;left, <span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;right)  {</div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;    <span class="keywordflow">return</span> <a class="code" href="_event_chain_element_8cpp.html#add80734c355c74ce27444a2f7d24aa59">operator&lt;</a>(right, left);</div>
<div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;}</div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;</div>
<div class="line"><a name="l00083"></a><span class="lineno"><a class="line" href="_event_chain_element_8cpp.html#a7e818a017933869ba62d5915e6a469d5">   83</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="_event_chain_element_8cpp.html#a7e818a017933869ba62d5915e6a469d5">operator&lt;=</a>(<span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;left, <span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;right)  {</div>
<div class="line"><a name="l00084"></a><span class="lineno">   84</span>&#160;    <span class="keywordflow">return</span> !<a class="code" href="_event_chain_element_8cpp.html#acabbca299f7a82dfe7a696f41f812f20">operator&gt;</a>(left, right);</div>
<div class="line"><a name="l00085"></a><span class="lineno">   85</span>&#160;}</div>
<div class="line"><a name="l00086"></a><span class="lineno">   86</span>&#160;</div>
<div class="line"><a name="l00097"></a><span class="lineno"><a class="line" href="_event_chain_element_8cpp.html#af33c0ba319798376c34c1147482140f8">   97</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="_event_chain_element_8cpp.html#af33c0ba319798376c34c1147482140f8">operator&gt;=</a>(<span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;left, <span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;right)  {</div>
<div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;    <span class="keywordflow">return</span> !<a class="code" href="_event_chain_element_8cpp.html#add80734c355c74ce27444a2f7d24aa59">operator&lt;</a>(left, right);</div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;}</div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;</div>
<div class="line"><a name="l00111"></a><span class="lineno"><a class="line" href="_event_chain_element_8cpp.html#a650f887b06045cd2bfda65d28f560812">  111</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="_event_8cpp.html#a33b5ef8ac3e21f9d655b1db577e0e69e">operator==</a>(<span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;left, <span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;right)  {</div>
<div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160;    <span class="keywordflow">return</span> (left.<a class="code" href="class_event_chain_element.html#adcae9fc863225f6b9ab43489895fed65">event</a> == right.<a class="code" href="class_event_chain_element.html#adcae9fc863225f6b9ab43489895fed65">event</a> &amp;&amp; left.<a class="code" href="class_event_chain_element.html#ae3d6217ce76ebe8603b89383ed63e7c6">eventTime</a> == right.<a class="code" href="class_event_chain_element.html#ae3d6217ce76ebe8603b89383ed63e7c6">eventTime</a>); </div>
<div class="line"><a name="l00113"></a><span class="lineno">  113</span>&#160;}</div>
<div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160;</div>
<div class="line"><a name="l00125"></a><span class="lineno"><a class="line" href="_event_chain_element_8cpp.html#a85c5a2421c78edf038183f2734507a61">  125</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="_event_8cpp.html#afb11938c92f98ab02bea1ebfd9de42a0">operator!=</a>(<span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;left, <span class="keyword">const</span> <a class="code" href="class_event_chain_element.html">EventChainElement</a> &amp;right)  {</div>
<div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;    <span class="keywordflow">return</span> !<a class="code" href="_event_8cpp.html#a33b5ef8ac3e21f9d655b1db577e0e69e">operator==</a>(left, right); </div>
<div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;}</div>
<div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;</div>
<div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;</div>
<div class="ttc" id="class_event_chain_element_html"><div class="ttname"><a href="class_event_chain_element.html">EventChainElement</a></div><div class="ttdoc">Defines an element for the Event Chain. </div><div class="ttdef"><b>Definition:</b> <a href="_event_chain_element_8h_source.html#l00036">EventChainElement.h:36</a></div></div>
<div class="ttc" id="class_event_html"><div class="ttname"><a href="class_event.html">Event</a></div><div class="ttdoc">Event class. </div><div class="ttdef"><b>Definition:</b> <a href="_event_8h_source.html#l00035">Event.h:35</a></div></div>
<div class="ttc" id="_event_8cpp_html_afb11938c92f98ab02bea1ebfd9de42a0"><div class="ttname"><a href="_event_8cpp.html#afb11938c92f98ab02bea1ebfd9de42a0">operator!=</a></div><div class="ttdeci">bool operator!=(const Event &amp;left, const Event &amp;right)</div><div class="ttdef"><b>Definition:</b> <a href="_event_8cpp_source.html#l00065">Event.cpp:65</a></div></div>
<div class="ttc" id="_event_chain_element_8cpp_html_af33c0ba319798376c34c1147482140f8"><div class="ttname"><a href="_event_chain_element_8cpp.html#af33c0ba319798376c34c1147482140f8">operator&gt;=</a></div><div class="ttdeci">bool operator&gt;=(const EventChainElement &amp;left, const EventChainElement &amp;right)</div><div class="ttdef"><b>Definition:</b> <a href="_event_chain_element_8cpp_source.html#l00097">EventChainElement.cpp:97</a></div></div>
<div class="ttc" id="class_event_chain_element_html_a5ea840974f6ff43044e2ae6323b8241c"><div class="ttname"><a href="class_event_chain_element.html#a5ea840974f6ff43044e2ae6323b8241c">EventChainElement::EventChainElement</a></div><div class="ttdeci">EventChainElement(double eventTime, const Event &amp;event)</div><div class="ttdoc">Constructor. </div><div class="ttdef"><b>Definition:</b> <a href="_event_chain_element_8cpp_source.html#l00040">EventChainElement.cpp:40</a></div></div>
<div class="ttc" id="class_event_chain_element_html_ae3d6217ce76ebe8603b89383ed63e7c6"><div class="ttname"><a href="class_event_chain_element.html#ae3d6217ce76ebe8603b89383ed63e7c6">EventChainElement::eventTime</a></div><div class="ttdeci">double eventTime</div><div class="ttdoc">Absolute occurrence time of event (= current time + occurAfterTime of event). </div><div class="ttdef"><b>Definition:</b> <a href="_event_chain_element_8h_source.html#l00038">EventChainElement.h:38</a></div></div>
<div class="ttc" id="_event_chain_element_8cpp_html_add80734c355c74ce27444a2f7d24aa59"><div class="ttname"><a href="_event_chain_element_8cpp.html#add80734c355c74ce27444a2f7d24aa59">operator&lt;</a></div><div class="ttdeci">bool operator&lt;(const EventChainElement &amp;left, const EventChainElement &amp;right)</div><div class="ttdef"><b>Definition:</b> <a href="_event_chain_element_8cpp_source.html#l00053">EventChainElement.cpp:53</a></div></div>
<div class="ttc" id="_event_chain_element_8cpp_html_acabbca299f7a82dfe7a696f41f812f20"><div class="ttname"><a href="_event_chain_element_8cpp.html#acabbca299f7a82dfe7a696f41f812f20">operator&gt;</a></div><div class="ttdeci">bool operator&gt;(const EventChainElement &amp;left, const EventChainElement &amp;right)</div><div class="ttdef"><b>Definition:</b> <a href="_event_chain_element_8cpp_source.html#l00069">EventChainElement.cpp:69</a></div></div>
<div class="ttc" id="_event_chain_element_8h_html"><div class="ttname"><a href="_event_chain_element_8h.html">EventChainElement.h</a></div></div>
<div class="ttc" id="_event_chain_element_8cpp_html_a7e818a017933869ba62d5915e6a469d5"><div class="ttname"><a href="_event_chain_element_8cpp.html#a7e818a017933869ba62d5915e6a469d5">operator&lt;=</a></div><div class="ttdeci">bool operator&lt;=(const EventChainElement &amp;left, const EventChainElement &amp;right)</div><div class="ttdef"><b>Definition:</b> <a href="_event_chain_element_8cpp_source.html#l00083">EventChainElement.cpp:83</a></div></div>
<div class="ttc" id="_event_8cpp_html_a33b5ef8ac3e21f9d655b1db577e0e69e"><div class="ttname"><a href="_event_8cpp.html#a33b5ef8ac3e21f9d655b1db577e0e69e">operator==</a></div><div class="ttdeci">bool operator==(const Event &amp;left, const Event &amp;right)</div><div class="ttdef"><b>Definition:</b> <a href="_event_8cpp_source.html#l00048">Event.cpp:48</a></div></div>
<div class="ttc" id="class_event_chain_element_html_adcae9fc863225f6b9ab43489895fed65"><div class="ttname"><a href="class_event_chain_element.html#adcae9fc863225f6b9ab43489895fed65">EventChainElement::event</a></div><div class="ttdeci">Event event</div><div class="ttdoc">Event object. </div><div class="ttdef"><b>Definition:</b> <a href="_event_chain_element_8h_source.html#l00039">EventChainElement.h:39</a></div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Mon Jan 6 2014 12:30:36 for QCNSim by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.5
</small></address>
</body>
</html>
